<template>
  <div v-for="(item, index) in dataList" :key="index" class="liList">
    <slot name="item" v-bind="item"></slot>
  </div>
</template>

<script>
export default {
  data() {
    return {
      dataList: [
        { body: 1, username: 1, likes: 1 },
        { body: 2, username: 2, likes: 2 },
        { body: 3, username: 3, likes: 3 },
      ],
    };
  },
};
</script>

<style>
.liList {
  border: 1px solid purple;
}
</style>
